Create order
curl --request POST \
--url https://firespark.cloud/api/storefront/v1/customers/{id}/orders \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"id": "<string>",
"fulfillment_id": "<string>",
"store_id": "<string>",
"channel_id": "<string>",
"brand_id": "<string>",
"is_anonymous": false,
"items": [
{}
],
"metadata": {}
}
'import requests
url = "https://firespark.cloud/api/storefront/v1/customers/{id}/orders"
payload = {
"id": "<string>",
"fulfillment_id": "<string>",
"store_id": "<string>",
"channel_id": "<string>",
"brand_id": "<string>",
"is_anonymous": False,
"items": [{}],
"metadata": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
id: '<string>',
fulfillment_id: '<string>',
store_id: '<string>',
channel_id: '<string>',
brand_id: '<string>',
is_anonymous: false,
items: [{}],
metadata: {}
})
};
fetch('https://firespark.cloud/api/storefront/v1/customers/{id}/orders', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://firespark.cloud/api/storefront/v1/customers/{id}/orders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'id' => '<string>',
'fulfillment_id' => '<string>',
'store_id' => '<string>',
'channel_id' => '<string>',
'brand_id' => '<string>',
'is_anonymous' => false,
'items' => [
[
]
],
'metadata' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://firespark.cloud/api/storefront/v1/customers/{id}/orders"
payload := strings.NewReader("{\n \"id\": \"<string>\",\n \"fulfillment_id\": \"<string>\",\n \"store_id\": \"<string>\",\n \"channel_id\": \"<string>\",\n \"brand_id\": \"<string>\",\n \"is_anonymous\": false,\n \"items\": [\n {}\n ],\n \"metadata\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://firespark.cloud/api/storefront/v1/customers/{id}/orders")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"id\": \"<string>\",\n \"fulfillment_id\": \"<string>\",\n \"store_id\": \"<string>\",\n \"channel_id\": \"<string>\",\n \"brand_id\": \"<string>\",\n \"is_anonymous\": false,\n \"items\": [\n {}\n ],\n \"metadata\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://firespark.cloud/api/storefront/v1/customers/{id}/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"id\": \"<string>\",\n \"fulfillment_id\": \"<string>\",\n \"store_id\": \"<string>\",\n \"channel_id\": \"<string>\",\n \"brand_id\": \"<string>\",\n \"is_anonymous\": false,\n \"items\": [\n {}\n ],\n \"metadata\": {}\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "ord-48291",
"brand_id": "0001",
"store_id": "downtown",
"channel_id": "app",
"customer_id": "cust-001",
"is_anonymous": false,
"fulfillment_id": "delivery",
"status": "OPEN",
"payment_status": "PENDING",
"fulfillment_status": "IDLE",
"totals": {
"currency": "USD",
"subtotal": 12.99,
"discount_total": 0,
"tax_total": 1.95,
"total": 14.94
}
}
}
Orders
Create order
Place a customer order from your owned channel into Fire spark.
POST
/
customers
/
{id}
/
orders
Create order
curl --request POST \
--url https://firespark.cloud/api/storefront/v1/customers/{id}/orders \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"id": "<string>",
"fulfillment_id": "<string>",
"store_id": "<string>",
"channel_id": "<string>",
"brand_id": "<string>",
"is_anonymous": false,
"items": [
{}
],
"metadata": {}
}
'import requests
url = "https://firespark.cloud/api/storefront/v1/customers/{id}/orders"
payload = {
"id": "<string>",
"fulfillment_id": "<string>",
"store_id": "<string>",
"channel_id": "<string>",
"brand_id": "<string>",
"is_anonymous": False,
"items": [{}],
"metadata": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
id: '<string>',
fulfillment_id: '<string>',
store_id: '<string>',
channel_id: '<string>',
brand_id: '<string>',
is_anonymous: false,
items: [{}],
metadata: {}
})
};
fetch('https://firespark.cloud/api/storefront/v1/customers/{id}/orders', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://firespark.cloud/api/storefront/v1/customers/{id}/orders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'id' => '<string>',
'fulfillment_id' => '<string>',
'store_id' => '<string>',
'channel_id' => '<string>',
'brand_id' => '<string>',
'is_anonymous' => false,
'items' => [
[
]
],
'metadata' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://firespark.cloud/api/storefront/v1/customers/{id}/orders"
payload := strings.NewReader("{\n \"id\": \"<string>\",\n \"fulfillment_id\": \"<string>\",\n \"store_id\": \"<string>\",\n \"channel_id\": \"<string>\",\n \"brand_id\": \"<string>\",\n \"is_anonymous\": false,\n \"items\": [\n {}\n ],\n \"metadata\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://firespark.cloud/api/storefront/v1/customers/{id}/orders")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"id\": \"<string>\",\n \"fulfillment_id\": \"<string>\",\n \"store_id\": \"<string>\",\n \"channel_id\": \"<string>\",\n \"brand_id\": \"<string>\",\n \"is_anonymous\": false,\n \"items\": [\n {}\n ],\n \"metadata\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://firespark.cloud/api/storefront/v1/customers/{id}/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"id\": \"<string>\",\n \"fulfillment_id\": \"<string>\",\n \"store_id\": \"<string>\",\n \"channel_id\": \"<string>\",\n \"brand_id\": \"<string>\",\n \"is_anonymous\": false,\n \"items\": [\n {}\n ],\n \"metadata\": {}\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "ord-48291",
"brand_id": "0001",
"store_id": "downtown",
"channel_id": "app",
"customer_id": "cust-001",
"is_anonymous": false,
"fulfillment_id": "delivery",
"status": "OPEN",
"payment_status": "PENDING",
"fulfillment_status": "IDLE",
"totals": {
"currency": "USD",
"subtotal": 12.99,
"discount_total": 0,
"tax_total": 1.95,
"total": 14.94
}
}
}
Creates a new order for the authenticated customer. This is how owned channels (app, web, kiosk) submit checkout into Fire spark. After creation, Fire spark routes the order to the merchant’s operational stack and notifies POS integrations via
order.injected.
Requires a Storefront API access token from Token
exchange.
What happens after you create an order
1
Your channel sends the checkout payload
Fire spark validates store, channel, fulfillment, and line items against
the composed menu for that selling context.
2
Fire spark stores the order
The order receives payment and fulfillment statuses based on your checkout
flow.
3
The POS receives the ticket
Fire spark notifies the merchant integration. When the
order.injected webhook fires, the
order is sent to the POS in its current state so the kitchen can start
preparation.Path parameters
| Parameter | Required | Description |
|---|---|---|
id | Yes | Customer identifier. Alphanumeric characters, _, and - only. 1–64 characters. |
Request body
| Field | Required | Type | Description |
|---|---|---|---|
id | Yes | string | External order id you assign. Must be unique per merchant. 1–64 characters. |
store_id | Yes | string | External store identifier where the order is prepared |
channel_id | Yes | string | External channel identifier (for example app, web) |
fulfillment_id | Yes | string | External fulfillment option (for example delivery, pickup) |
brand_id | No | string | External brand identifier when ordering under a specific brand |
is_anonymous | No | boolean | Set to true for guest checkout without a registered customer profile. Defaults to false. The customer_id path parameter is still required and identifies the session or guest record. |
items | No | array | Line items with product ids, quantities, and modifier selections |
metadata | No | object | Channel-specific metadata. Defaults to {}. |
Request
curl -X POST "https://firespark.cloud/api/storefront/v1/customers/cust-001/orders" \
-H "Authorization: Bearer ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"id": "ord-48291",
"brand_id": "0001",
"store_id": "downtown",
"channel_id": "app",
"fulfillment_id": "delivery",
"is_anonymous": false,
"items": [
{
"id": "burger-classic",
"quantity": 1,
"modifiers": []
}
],
"metadata": {
"cart_session_id": "sess_abc123"
}
}'
Response
Returns201 with the created order in data.
{
"data": {
"id": "ord-48291",
"brand_id": "0001",
"store_id": "downtown",
"channel_id": "app",
"customer_id": "cust-001",
"is_anonymous": false,
"fulfillment_id": "delivery",
"status": "OPEN",
"payment_status": "PENDING",
"fulfillment_status": "IDLE",
"totals": {
"currency": "USD",
"subtotal": 12.99,
"discount_total": 0,
"tax_total": 1.95,
"total": 14.94
}
}
}
Generate the external
id on your server before calling POST so you can retry
safely if the network fails. Use the same id on retry — Fire spark rejects
duplicate ids for the same merchant.Error responses
| Status | Description |
|---|---|
401 | Missing or invalid access token |
404 | Customer not found |
422 | Invalid store, channel, fulfillment, or line items |
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Customer identifier.
Required string length:
1 - 64Pattern:
^[a-zA-Z0-9_-]+$Body
application/json
Order to create.
Required string length:
1 - 64Pattern:
^[a-zA-Z0-9_-]+$Required string length:
1 - 64Pattern:
^[a-zA-Z0-9_-]+$Required string length:
1 - 64Pattern:
^[a-zA-Z0-9_-]+$Required string length:
1 - 64Pattern:
^[a-zA-Z0-9_-]+$Required string length:
1 - 64Pattern:
^[a-zA-Z0-9_-]+$Response
201 - application/json
Ok
⌘I